package com.bst.etl.datax.service;

import com.bst.datatx.core.biz.model.ReturnT;
import com.bst.etl.datax.core.trigger.TriggerTypeEnum;
import com.bst.etl.datax.dto.TriggerJobDto;
import com.bst.etl.datax.entity.JobTemplate;

import java.util.List;

/**
 * core job action for datax-web
 * 
 * @author xuxueli 2016-5-28 15:30:33
 */
public interface JobTemplateService {
	/**
	 * page list
	 *
	 * @return
	 */
	List<JobTemplate> selectJobTemplateList(JobTemplate jobTemplate);
	/**
	 * add job
	 *
	 * @param jobTemplate
	 * @return
	 */
	ReturnT<String> add(JobTemplate jobTemplate);

	/**
	 * update job
	 *
	 * @param jobTemplate
	 * @return
	 */
	ReturnT<String> update(JobTemplate jobTemplate);

	/**
	 * remove job
	 * 	 *
	 * @param id
	 * @return
	 */
	ReturnT<String> remove(int id);

	void jobTemplateTrigger(TriggerJobDto dto, TriggerTypeEnum triggerType);
}
